﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
using com.Editors.Code;

namespace com.Editors.UserControls
{
    public partial class UIClientScript : Form
    {
        com.code.Editors.Code.GuidDataColumn colObj;
        
        public UIClientScript(com.code.Editors.Code.GuidDataColumn col, Point p)
        {
            InitializeComponent();
            
            this.Left = p.X;
            this.Top = p.Y;
            this.ShowInTaskbar = false;
            this.FormBorderStyle = FormBorderStyle.FixedDialog;
            this.colObj = col;
            //this.Capture = true;
        }

        private void btnSubmit_Click(object sender, EventArgs e)
        {
            colObj.IsRange = this.chkRange.Checked;
            colObj.IsValidNum = chkValidNum.Checked;
            colObj.IsRequired = chkRequired.Checked;
            colObj.FromNumRange = txtFrom.Text;
            colObj.ToNumRange = txtTo.Text;
            colObj.IsValidDate = chkDate.Checked;
            colObj.IsValidEmail = chkEmail.Checked;
            colObj.MsgCaption = txtMsgCaption.Text;
            this.Close();
        }

       
    }
}
